﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using WMPLib;

namespace Imagine_Cup
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
            Player.URL = @"C:\Users\shady\Desktop\lights out\House M.D. [1x07] Fidelity (XviD asd).avi";
            myTimer.Interval = 10;
            myTimer.Start();
        }

        private void button1_Click(object sender, EventArgs e)
        {
            //label1.Text = Player.currentMedia.duration.ToString();
            
            // get/set current time
            //label1.Text = Player.Ctlcontrols.currentPosition.ToString();

            MessageBox.Show (Player.playState.ToString());

            Player.Ctlcontrols.currentPosition = 100;
        }

        private void Player_Enter(object sender, EventArgs e)
        {
            Player.uiMode = "none";
        }

        private void myTimer_Tick(object sender, EventArgs e)
        {
            if (5.0 < Player.Ctlcontrols.currentPosition && Player.Ctlcontrols.currentPosition <= 100.0)
            {
                Player.Ctlcontrols.currentPosition = 300;
            }
        }

        
        
    }
}
